home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 52 / Amiga Format AFCD52 (Issue 136, May 2000).iso / -serious- / hardware / ahd12 / prep / prep.c < prev   
C/C++ Source or Header  |  2000-02-28  |  1KB  |  72 lines

  1. #include "exec/types.h"
  2.  
  3. UWORD buffer[256];
  4.  
  5. void
  6. main()
  7.    {
  8.    int temp;
  9.  
  10.    puts("Cylinders");
  11.    flushall();
  12.    scanf("%d", &temp);
  13.    buffer[0] = temp;
  14.  
  15.    puts("Precomp");
  16.    flushall();
  17.    scanf("%d", &temp);
  18.    buffer[1] = temp;
  19.  
  20.    puts("Sectors");
  21.    flushall();
  22.    scanf("%d", &temp);
  23.    buffer[2] = temp;
  24.  
  25.    puts("Heads");
  26.    flushall();
  27.    scanf("%d", &temp);
  28.    buffer[3] = temp;
  29.  
  30.    puts("Interleave");
  31.    flushall();
  32.    scanf("%d", &temp);
  33.    buffer[4] = temp;
  34.  
  35.    puts("Steprate");
  36.    flushall();
  37.    scanf("%d", &temp);
  38.    buffer[5] = temp;
  39.  
  40.    puts("ECC Burst length");
  41.    flushall();
  42.    scanf("%d", &temp);
  43.    buffer[6] = temp;
  44.  
  45.    printf("Reset...");
  46.    flushall();
  47.    doreset();
  48.  
  49.    printf("Format 0...");
  50.    flushall();
  51.    fmthard(0L);
  52.  
  53.    printf("Write...");
  54.    flushall();
  55.    writehardsec(buffer,0L,512L);
  56.  
  57.    printf("Reset...");
  58.    flushall();
  59.    doreset();
  60.  
  61.    printf("Config...");
  62.    flushall();
  63.    hdconfig(buffer);
  64.  
  65.    printf("Init...");
  66.    flushall();
  67.    doinit();
  68.  
  69.    puts("Done");
  70.    }
  71.  
  72.